<!DOCTYPE html>
<html lang="en" xmlns:th="http://www.w3.org/1999/xhtml">
<head>
    <title>books</title>
    <meta charset="UTF-8"/>
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <!-- Bootstrap -->
    <link href="https://cdn.jsdelivr.net/npm/bootstrap@3.3.7/dist/css/bootstrap.min.css" rel="stylesheet">
    <link rel="stylesheet" th:href="@{/css/bootstrap.min.css}" href="../static/css/bootstrap.min.css">
</head>
<body>
<div class="container">
    <h2 class="page-header">书单列表</h2>
    <div class="alert alert-success alert-dismissable fade in" th:if="${(message)!=null}">
        <a href="#" class="close" data-dismiss="alert">&times;</a>
        <strong>恭喜，</strong>
        <span th:text="${message}">信息提交成功</span>
    </div>
    <p class="text-right"><a href="./input.html" th:href="@{/books/input}" class="btn btn-primary">刷新</a></p>
    <table class="table table-bordered table-striped table-hover">
        <thead>
        <tr>
            <th>#</th>
            <th>作者</th>
            <th>说明</th>
        </tr>
        </thead>
        <tbody>
        <!--
        iterStat：
        count:计数 从1开始
        index:索引 从0开始
        size:列表总条数
        even/odd:偶数/奇数
        first/last:第一行、最后一行
        th:class="${iterStat.even}? 'bg-success'"
        -->
        <p th:text="${json}">${json}</p>
        </tbody>

    </table>

</div>
<!-- jQuery (Bootstrap 的所有 JavaScript 插件都依赖 jQuery，所以必须放在前边) -->
<script src="https://cdn.jsdelivr.net/npm/jquery@1.12.4/dist/jquery.min.js"></script>
<!-- 加载 Bootstrap 的所有 JavaScript 插件。你也可以根据需要只加载单个插件。 -->
<script th:src="@{/js/bootstrap.min.js}" src="../static/js/bootstrap.min.js"></script>

</body>
</html>